Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

inject for free programs #1526

Merged
merged 3 commits into from
Jan 25, 2017
Merged

inject for free programs #1526

merged 3 commits into from
Jan 25, 2017

Conversation

tpolecat
Copy link
Member

This adds an inject operation for Free that lifts programs rather than constructors. This allows you to use existing Free programs (like doobie ConnectionIO) in coproducts without having to write implicit modules of lifted constructors.

I'll add a test if people think this is useful.

@ceedubs
Copy link
Contributor

ceedubs commented Jan 24, 2017

I think that this is a handy method. But it looks like you have a compile error :)

The implementation is fairly trivial, but I think at least an sbt-doctest example (if not also a separate test) would be great.

@tpolecat
Copy link
Member Author

Doh, I was compiling core instead of free.

@codecov-io
Copy link

codecov-io commented Jan 24, 2017

Current coverage is 92.26% (diff: 100%)

Merging #1526 into master will increase coverage by <.01%

@@             master      #1526   diff @@
==========================================
  Files           246        246          
  Lines          3763       3764     +1   
  Methods        3637       3639     +2   
  Messages          0          0          
  Branches        126        125     -1   
==========================================
+ Hits           3472       3473     +1   
  Misses          291        291          
  Partials          0          0          

Powered by Codecov. Last update be176fa...40041dd

@ceedubs
Copy link
Contributor

ceedubs commented Jan 24, 2017

👍 LGTM

@adelbertc
Copy link
Contributor

👍 LGTM

@adelbertc adelbertc merged commit d0166d8 into typelevel:master Jan 25, 2017
@stew stew removed the in progress label Jan 25, 2017
@tpolecat tpolecat deleted the inj branch January 25, 2017 02:33
@kailuowang kailuowang modified the milestone: 1.0.0-MF Apr 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants